<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org"
      th:replace="fragments/layout(title='护理管理-添加',cssPaths='/static/css/services/records/add.css',jsPaths='/static/js/services/records/add.js')">
<div class="right" th:fragment="right">
    <!--面包屑-->
    <div class="breadcrumb layui-bg-gray">
                <span class="layui-breadcrumb" lay-separator=">">
                    <a th:href="@{/}">首页</a>
                    <a href="">护理管理</a>
                    <a href="/records">护理记录</a>
                    <a><cite>新增</cite></a>
                </span>
    </div>

    <!--主体内容区-->
    <div class="form-content layui-container">
        <div class="layui-row">
            <table class="layui-table" lay-skin="nob">
                <colgroup>
                    <col width="150">
                    <col width="200">
                    <col>
                </colgroup>
                <tr>
                    <td>
                        <a href="/records/add?healthCondition=0" class="layui-btn layui-btn-primary">全部</a>
                        <a href="/records/add?healthCondition=1" class="layui-btn layui-btn-primary">具备自理能力</a>
                        <a href="/records/add?healthCondition=2" class="layui-btn layui-btn-primary">部分丧失自理能力</a>
                        <a href="/records/add?healthCondition=3" class="layui-btn layui-btn-primary">完全丧失自理能力</a>
                    </td>
                </tr>
            </table>
        </div>
        <div class="elder-box">
            <div th:each="elderlies:${elderlies}" class="findItems">
            <input type="hidden" id="itemId" th:value="${elderlies.id}">
            <div class="elder-item">
                <p style="text-align: center;width: 100px;margin-top: 15px;margin-bottom:20px;"
                   th:if="${elderlies.buildingNo!=null && elderlies.buildingNo!='' && elderlies.roomNo!=null && elderlies.roomNo!='' && elderlies.bedNo!=null && elderlies.bedNo!=''}"
                   th:text="${elderlies.buildingNo}+'-'+${elderlies.roomNo}+'-'+${elderlies.bedNo}"></p>
                <img th:if="${elderlies.avatar==null || elderlies.avatar==''}"
                     style="width: 100px;height: 100px; border-radius: 50%;" src='/static/imgs/elder.png'>
                <img th:if="${elderlies.avatar!=null &&  elderlies.avatar!=''}"
                     style="width: 100px;height: 100px; border-radius: 50%;"
                     th:src="@{'/storage/files/'+${elderlies.avatar}}">
                <p style="text-align: center;width: 100px;margin-top: 15px;margin-bottom:20px;">
                    <span style="font-size: 18px;" th:text="${elderlies.name}"></span>
                </p>
            </div>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-input-block">
                <a class="layui-btn" href="/records">返回</a>
            </div>
        </div>
    </div>
</div>
</html>